<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        /*去掉所有的内外边距*/
        *{
            padding: 0;
            margin: 0;
        }
        ul,li{
            list-style: none;/*去掉圆点*/
        }
        a{
            text-decoration: none;
        }
        span{
            display: inline-block;
            width: 25px;
            height: 25px;
            line-height: 25px;/*行高,和高度一样,实现垂直居中效果*/
            text-align: center;
            border-radius: 50%;
            background: black;
            margin: 2px 5px;
            color: white;
        }
        li{
            height: 25px;
            line-height: 25px;
            margin-top: 2px ;
            border-bottom: 1px dashed grey;
            padding-bottom: 2px;
        }
        a:hover{
            color: red;
        }
        a:hover span{
            background: red;
            color: white;
        }
    </style>
</head>
<body>
<ul>
    <li><a href=""><span>1</span>列表一</a></li>
    <li><a href=""><span>2</span>列表二</a></li>
    <li><a href=""><span>3</span>列表三</a></li>
    <li><a href=""><span>4</span>列表四</a></li>
    <li><a href=""><span>5</span>列表五</a></li>
</ul>
</body>
</html>